<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use Illuminate\Foundation\Auth\User as Authenticatable;
class Expert extends Authenticatable
{
    use HasFactory;
    public function Videos(){
        return $this->belongsToMany(
            Video::class,
            'middle_tables',
            'expert_id',
            'video_id');
    }
    protected $fillable=['name','chenghao','job','thumb','department','hospital','introduction','education'];
    use SoftDeletes;//软删除
}
